package actions;

import java.sql.SQLException;
import java.util.Vector;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
import javax.sql.rowset.CachedRowSet;

import model.Applicant;
import model.Database;

import org.apache.struts.action.Action;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;

import db.DbException;
import forms.ResidencySubmitForm;

public class ApplicationsAction extends Action {
	public ActionForward execute(ActionMapping mapping, ActionForm form,
			HttpServletRequest request, HttpServletResponse response)
			throws DbException {
		
		HttpSession session = request.getSession();
		
		
	//	try { 
//			Vector applicants = (Vector) Database.getGradedByReviewer(reviewer);
//			CachedRowSet graded = (CachedRowSet)Database.getAllGraded();
//			CachedRowSet notGraded = (CachedRowSet)Database.();
//			
//			
//			session.setAttribute("graded", graded);
//			session.setAttribute("notGraded", notGraded);
////			session.setAttribute("reviewers", reviewers);
//		} catch (ClassNotFoundException e) {
//			// TODO Auto-generated catch block
//			e.printStackTrace();
//		} catch (SQLException e) {
//			// TODO Auto-generated catch block
//			e.printStackTrace();
//		}
//		
		return mapping.findForward("success");
	}
}
